package com.ruoyi.business.shop.service.impl;

import com.ruoyi.business.shop.api.domain.Shop;
import com.ruoyi.business.shop.mapper.ShopMapper;
import com.ruoyi.business.shop.service.IShopService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 店铺信息Service业务层处理
 *
 * @author gcc
 * @date 2025-02-21
 */
@Service
public class ShopServiceImpl implements IShopService {
    @Autowired
    private ShopMapper shopMapper;



    /**
     * 查询店铺信息
     *
     * @param id 店铺信息主键
     * @return 店铺信息
     */
    @Override
    public Shop selectShopById(Long id) {
        return shopMapper.selectShopById(id);
    }

    /**
     * 查询店铺信息列表
     *
     * @param shop 店铺信息
     * @return 店铺信息
     */
    @Override
    public List<Shop> selectShopList(Shop shop) {


        return shopMapper.selectShopList(shop);
    }

    /**
     * 新增店铺信息
     *
     * @param shop 店铺信息
     * @return 结果
     */
    @Override
    public int insertShop(Shop shop) {
        return shopMapper.insertShop(shop);
    }

    /**
     * 修改店铺信息
     *
     * @param shop 店铺信息
     * @return 结果
     */
    @Override
    public int updateShop(Shop shop) {
        return shopMapper.updateShop(shop);
    }

    /**
     * 批量删除店铺信息
     *
     * @param ids 需要删除的店铺信息主键
     * @return 结果
     */
    @Override
    public int deleteShopByIds(Long[] ids) {
        return shopMapper.deleteShopByIds(ids);
    }

    /**
     * 删除店铺信息信息
     *
     * @param id 店铺信息主键
     * @return 结果
     */
    @Override
    public int deleteShopById(Long id) {
        return shopMapper.deleteShopById(id);
    }





}
